======== DOUKUTSU ASSEMBLER SOURCE CODE FOR VERSION 1.31 ========

Well, here it is. You've downloaded the source code for some weird reason, and
now it's time to talk about how you'll go about editing it.

I'll assume that you have Java programming experience and understand how to
create a graphical-user-interface program using Java's Swing toolkit.

First of all, let me warn you that there is a lack of documentation. I was
originally planning to write doc-comments for every single method and class in
the source code, but then I realized that would take forever.

So I'm sorry if you get horribly confused while editing the code. (Heck, I get
confused all the time when editing my own code! I wouldn't want to imagine
what would happen to somebody else... uh.. disregard that.)

If I can't leave you with good documentation, I can at least leave you with
the right tools. Here are the programs, guides, etc. that I used while creating
the Doukutsu Assembler. Also, feel free to contact me to ask questions about
the source code and such.

The Official Java Tutorials
http://download.oracle.com/javase/tutorial/
(Personally I think these tutorials aren't explained very well but they are
indeed the official ones.)

Stack Overflow
http://stackoverflow.com/questions/tagged/java
(Stack overflow is a community-driven Q & A website that will answer a ton
of your existing programming problems)

Netbeans IDE
http://netbeans.org/
(This is an incredible code editor for Java. It can catch your syntax errors
before you compile your code. Errors are underlined with a wavy red line just
like misspelled words in a word processor. It also offers powerful tools and
code refactoring.)

Notepad++
http://notepad-plus-plus.org/
(A better version of Windows Notepad aimed toward programmers. I use this to
edit my binary table source code.)

Intel(R) Architecture Software Developer's Manual, Volume 2
http://www.intel.com/design/intarch/manuals/243191.htm
(Download this PDF. It has information on the structure of every instruction
supported by x86 computer chips. I will refer to this as the Intel PDF.)

======== THE BINARY TABLE ========
There is a special file that was included in your download, and that would be
the binary table source code.

To add in new instructions (real instructions - not the lame way by using
defines), you definitely need to edit the binary table file. I suggest that
you open the binary table in Notepad++ and set the language to C. No, the
binary table is not written in C, but using C's syntax coloration makes the
file a lot easier to edit.

The Doukutsu Assembler doubles as a binary-table-compiler. There is a method
in the class AssemblerGUI that is declared as private void compileBinTable().
The entire method is commented out, so be sure to uncomment it. Attach the
compileBinTable() method to a GUI button, and you're set to go.

The format of the binary table is based off of the table starting on page 796
of the Intel PDF. You should read the Intel PDF to understand how the table
works.

No - you don't have to read all 854 pages. The important sections exist on
the following pages:

Page 31 - 37
Page 791 - 808

Maybe I'm forgetting some sections, but the two I've mentioned are probably
the most important ones.

Thank you for your patience and perseverance. Good luck.

--Carrotlord


